//
//  ST_Refresh.h
//  ST_BaseMall
//
//  Created by 昱胜 on 2022/9/2.
//

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

/**
 *  集成刷新控件
 */
typedef NS_ENUM(NSUInteger, ST_RefreshOption) {
    ST_RefreshNone         = 0,
    ST_HeaderRefresh       = 1 << 0,
    ST_FooterRefresh       = 1 << 1,
    ST_HeaderAutoRefresh   = 1 << 2,
    ST_FooterAutoRefresh   = 1 << 3,
    ST_FooterDefaultHidden = 1 << 4,
    ST_RefreshDefault = (ST_HeaderRefresh | ST_HeaderAutoRefresh | ST_FooterRefresh | ST_FooterDefaultHidden),
};
@protocol ST_RefreshDataSource <NSObject>

@required
- (NSArray <UIImage *>*)refreshFooterData;
- (NSArray <UIImage *>*)refreshHeaderData;
- (NSArray <UIImage *>*)refreshLoaderData;
- (UIImage *)refreshEmptyData;
- (UIImage *)refreshErrorData;
@optional
- (NSString *)refreshLoaderToast;
- (NSString *)refreshErrorToast;
- (NSString *)refreshEmptyToast;
@end


@interface ST_Refresh : NSObject

+ (UIColor *)colorWithRGB:(uint32_t)rgbValue;
+ (CGFloat)NAVI_HIGHT;
+ (BOOL)reachable;

@end

NS_ASSUME_NONNULL_END
